<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<link href="../../../js/bootstrap-3.3.7-dist/css/bootstrap.min.css" rel="stylesheet">
		<link rel="stylesheet" type="text/css" href="../../../css/footer.css" />
		<link rel="stylesheet" type="text/css" href="css/gold_detail.css" />
		<style type="text/css">
			/*修改底部字体颜色*/
			
			.foot:nth-child(2) {
				color: #e83023;
			}
			body{
				background-color: #F7F7F7;
			}
			#list li{border-bottom: 0.013888rem solid #dfdfdf;}
		</style>
		<script src="../../../js/flexible.min.js" type="text/javascript" charset="utf-8"></script>
	</head>

	<body>
		<div id="wrap">
			<div id="main">
				<div id="header">
					<a id="headImg" href="javascript:history.go(-1)"><img class="headImg" src="../../../images/12.png" /></a>
					<p id="headTitle">金币明细</p>
				</div>
				<div id="content">
					<!--内容-->
					<ul id="list">

					</ul>

				</div>
			</div>
			
		</div>

	</body>
	<script src="../../../js/jquery-2.2.3.min.js"></script>
	<script src="../../../js/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script>
	<script src="../../../js/jquery.cookie.js" type="text/javascript" charset="utf-8"></script>
	<script type="text/javascript">
		//会员id
		var memberId = "snow";
		var pageNum = 1;
		var pageSize = 1000;
		$.ajax({
			type: "get",
			url: "http://47.104.13.109/member-service/member/mine/member?token=" + $.cookie('tokenRh'),
			async: false,
			success: function(data) {
				console.log(data);
				memberId = data.id;
			}
		});
		$.ajax({
			type: "get",
			url: "http://47.104.13.109/gold-service/tfGoldDetailList",
			async: true,
			data: {
				memberId : memberId,
				pageNum: pageNum,
				pageSize: pageSize
			},
			success: function(data) {
				console.log(data);
				var str = "";
				for (var i = 0;i < data.list.length;i++) {
					if (data.list[i].gdStatus == 1) {
//						console.log(data.list[i].gdStatus)
						str += '<li><a href="gold_details.html?gdId=' + data.list[i].gdId + '"><p>新增金币<span>'+data.list[i].gdTime+'</span></p><p class="txt">'+data.list[i].gdRemark+'</p></a></li>';
					}else{
						str += '<li><a href="gold_details.html?gdId=' + data.list[i].gdId + '"><p>消费金币<span>'+data.list[i].gdTime+'</span></p><p class="txt">'+data.list[i].gdRemark+'</p></a></li>'
					}
					
				}
				$("#list").append(str);
			}
		});
	</script>
</html>